package ctu.edu.vn.musicmanager.gui;

import javax.jms.JMSException;

public class Main {

	public static void main(String[] args) {

		MusicManager mm;
		try {
			mm = new MusicManager();
			mm.setVisible(true);
		} catch (Exception e) {
			
			e.printStackTrace();
		}
		
	
	}

}
/* Phần test dữ liệu 
 * Insert data into database 
ms.setID(2);
ms.setName("Le Cong Tinh");
ms.setType("mp3");
System.out.println("Saving ...");
msORM.save(ms);*/

/* Update data into database 
ms.setID(2);
ms.setName("Boi vi anh yeu em");
ms.setType("mp3");
System.out.println("Updating ...");
msORM.update(ms);*/

/* Delete data by id error
System.out.println("Deleting ...");
msORM.deleteMusic(1);*/

/* Fetch All Data from Database error 
//System.out.println("Fetching ...");
//msORM.fetchAllMusic();*/

/* Fetch every id
for(Object o : msORM.fetchAllMusic()) {
    Music p = (Music)o;
    System.out.println(p.getID()); 
}
//dinh dang hien thi cot
		DefaultTableCellRenderer defaultRenderer = new DefaultTableCellRenderer();
        defaultRenderer.setHorizontalAlignment(JLabel.CENTER);
        table.getColumnModel().getColumn(2).setCellRenderer(defaultRenderer);
*/

//System.out.println("Fetching updated player : "+ msORM.getMusic(1));

